const obj = {
    a:1,
    b:1
}
function test(fn1,fn2){
    console.log(fn1 , fn2,this)
    return 'test返回值'
}

Function.prototype.myCall = function(ctx){
    const argu = [...arguments]
    argu.shift()
    const pointer = ctx ? Object(ctx): window
    pointer.__proto__.fn = this
    const ret = pointer.fn(...argu)
    delete pointer.__proto__.fn
    return ret
}
console.log(test.myCall(obj,'参数1','参数2'))
